import httpInstant from '@/utils/http';

/**
 * @description 根据分类id获取简单帖子列表
 * @param categoryId 分类id
 * @returns
 */
export function getSimplePostApi(categoryId) {
  return httpInstant.get(`/post/getSimplePost?categoryId=${categoryId}`)
}

/**
 * @description 主页获得所有帖子中热度最高的10个帖子
 * @returns
 */
export function getAllSimplePost() {
  return httpInstant.get('/post/getAllSimplePost')
}


/**
 * @description 根据分类id获取该分类下所有帖子
 * @param categoryId 分类id
 * @returns
 */
export function getCategoryAllSimplePostApi(categoryId) {
  return httpInstant.get(`/post/getCategoryAllSimplePost?categoryId=${categoryId}`)
}